/*
 * Copyright 2022-2029 heshuixing(https://gitee.com/heshuixing)
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.mercury.ec.module.air.controller.admin.search.vo.flight;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.List;

import static com.mercury.ec.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY;

/**
 * 航班查询 Response VO
 *
 * @author hesx
 */
@Data
@Schema(description = "管理后台 - 航班查询 Response VO")
public class AirSearchFlightRespVO {

    @Schema(description = "出发日期", requiredMode = Schema.RequiredMode.REQUIRED, example = "2022-02-02")
    @JsonFormat(pattern = FORMAT_YEAR_MONTH_DAY)
    private LocalDate flightDate;

    @Schema(description = "出发地三字码", requiredMode = Schema.RequiredMode.REQUIRED, example = "CAN")
    private String depart;

    @Schema(description = "出发城市名", requiredMode = Schema.RequiredMode.REQUIRED, example = "广州")
    private String departCityName;

    @Schema(description = "目的地三字码", requiredMode = Schema.RequiredMode.REQUIRED, example = "CAN")
    private String arrive;

    @Schema(description = "目的城市名", requiredMode = Schema.RequiredMode.REQUIRED, example = "上海")
    private String arriveCityName;

    @Schema(description = "航班数", requiredMode = Schema.RequiredMode.REQUIRED, example = "100")
    private Integer total = 0;

    @Schema(description = "更新时间", requiredMode = Schema.RequiredMode.REQUIRED, example = "2022-02-02 00:00:00")
    private LocalDateTime updateTime;

    @Schema(description = "航班列表")
    private List<AirFlightRespVO> flights;
}
